<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<script src="${pageContext.request.contextPath}/js/Echarts/china.js"></script>

<style>
.labelspan{
    float: left;
    font-weight: bold;
    font-size: 11px;
    margin-right: 3%;
}

.btnarea{
    width: 44%;
    float: right;
    margin-right: 9%;
    margin-top: 3%;
}
</style>

<div ng-controller="searchPageController as controller">
	<div class="wrap">
		<div class="mapTips">
			<h6>
				<i class="glyphicon glyphicon-cog"></i> <span>条件设置</span>
			</h6>
		</div>
		<div class="conditionWrap">
			<div class="wrapFirst" style="height: 103px; margin-bottom: 50px;margin-top: 10px">
				<form role="form" name="tableForm" class="form-horizontal">
					<div class="form-group">
						<div class="row">
							<div class="col-md-4 col-sm-4 col-xs-4">
								<label for="input-userNo_search" class="control-label labelspan"
									style="padding: 19px 6px 0 10%;float:left;font-weight: bold;font-size: 11px;">用户工号:</label>
								<div>
									<input style="width: 60%; height: 34px;border-radius: 4px;margin-top: 10px;"
										ng-model="controller.queryCondition.userNo" type="text"
										class="form-control" id="input-userNo_search" placeholder="工号">
								</div>
							</div>
							<div class="col-md-4 col-sm-4 col-xs-4">
								<label for="input-userNo_search" class="control-label labelspan"
									style="padding: 19px 6px 0 6%;float:left;font-weight: bold;font-size: 11px;">用户姓名:</label>
								<div>
									<input type="text" class="form-control" 
									style="width: 60%; height: 34px;border-radius: 4px;margin-top: 10px;"
										id="input-userName_search"
										ng-model="controller.queryCondition.userName" placeholder="姓名">
								</div>
							</div>
							<div class="col-md-4 col-sm-4 col-xs-4">
								<label for="input-userNo_search" class="control-label labelspan"
									style="padding: 19px 6px 0 6%;float:left;font-weight: bold;font-size: 11px;">所属区域:</label>
								<div>
									<input ng-model="controller.queryCondition.belong_to_reglon"
									style="width: 60%; height: 34px;border-radius: 4px;margin-top: 10px;"
										type="text" class="form-control"
										id="input-belong_to_reglon_search" placeholder="区域">
								</div>
							</div>
						</div>		
						<div class="row">
							<div class="col-md-4 col-sm-4 col-xs-4">
									<label for="input-userNo_search" class="control-label labelspan"
									style="padding: 19px 6px 0 10%;float:left;font-weight: bold;font-size: 11px;">所属部门:</label>
								<div>
									<input type="text" class="form-control"
									style="width: 60%; height: 34px;border-radius: 4px;margin-top: 10px;"
										id="input-belong_to_department_search"
										ng-model="controller.queryCondition.belong_to_department"
										placeholder="部门">
								</div>
							</div>
							<div class="col-md-4 col-sm-4 col-xs-4">
								<label for="input-userNo_search" class="control-label "
									style="padding: 19px 6px 0 6%;float:left;font-weight: bold;font-size: 11px;">账号有效期:</label>
								<div>
									<input type="text" class="form-control"
										style="width: 60%; height: 34px;border-radius: 4px;margin-top: 10px;"
										uib-datepicker-popup="{{controller.format}}"
										ng-model="controller.queryCondition.date"
										is-open="controller.popup1.opened" close-text="关闭"
										clear-text="清空" current-text="今天"
										alt-input-formats="controller.altInputFormats"
										datepicker-options="controller.dateOptions"
										ng-change="controller.changeDate();"
										ng-click="controller.open1();" placeholder="有效期" />
								</div>
							</div>
							<div class="col-md-4 col-sm-4 col-xs-4">
								<div class="btnarea" >
									<button type="button" class="btn btn-primary" style="margin-right:6px; width:40%" 
											ng-click="controller.search()">搜索
									</button>
									<button type="button" class="btn btn-danger" style="width:40%" 
										ng-click="controller.reset()">重置
									</button>
								</div>
							</div>
					
						</div>
						<div  style="padding: 19px 0 0 15px;">
							<button class="btn btn-default"
								style="float:left; margin: 2px 8px 10 0;"
								type="button" ng-click="controller.addUser()">新增用户</button>
						</div>
						<div style="float:left;margin: 2px 8px 10 0;">
							<button class="btn btn-default" type="button"
								ng-click="controller.delUser();">删除用户</button>
						</div>

						<div style="float:left;margin: 2px 8px 10 0;">
							<button class="btn btn-default dropdown-toggle" type="button"
								id="dropdownMenu2" data-toggle="dropdown" aria-haspopup="true"
								aria-expanded="false">
								Dropup <span class="caret"></span>
							</button>
							<ul class="dropdown-menu" aria-labelledby="dropdownMenu2">
								<li><a href="#">Action</a></li>
								<li><a href="#">Another action</a></li>
								<li><a href="#">Something else here</a></li>
							</ul>
						</div>

					
				</div>

					<div class="form-group"></div>
				</form>
			</div>


		</div>

		<div class="mapBottom table-bordered"
			style="font-size: 13px; background: white;">
			<table class="table table-bordered" style="font-size: 13px;">
				<tr>
					<th style="width: 1%"><input type="checkbox" id="check_all" /></th>
					<th>用户工号</th>
					<th>用户姓名</th>
					<th>性别</th>
					<th>所属区域</th>
					<th>所在部门</th>
					<th>电子邮箱</th>
					<th>电话</th>
					<th>账号有效期</th>
					<th>角色</th>
					<th style="width: 11%;">操作</th>
				</tr>

				<tr ng-repeat="data in controller.dataList">
					<td><input type="checkbox" class="check_item" /></td>
					<td ng-hide="true">{{data.id}}</td>
					<td>{{data.userNo}}</td>
					<td>{{data.userName}}</td>
					<td>{{data.gender}}</td>
					<td>{{data.belongToReglon}}</td>
					<td>{{data.belongToDepartment}}</td>
					<td>{{data.emai}}</td>
					<td>{{data.telephone}}</td>
					<td>{{data.accountValidityPeriod}}</td>
					<td>{{data.roleName}}</td>
					<td>
						<button ng-click="controller.editUserInfo(data)"
							class="btn btn-primary btn-sm update_btn">详情</button>
						<button class="btn btn-danger btn-sm delete_btn">删除</button>
					</td>

				</tr>
			</table>
			<div class="spagination"
				style="padding-bottom: 63px; position: relative; margin-left: 25%; margin-top: -3%;">
				<div style="position: absolute; margin-left: -10%; margin-top: 3%;">总{{controller.paginationInfo.totalElements}}条记录</div>
				<div style="position: absolute; left: 0px;">
					<ul uib-pagination
						total-items="controller.paginationInfo.totalPages"
						ng-model="controller.queryCondition.page"
						max-size="controller.paginationInfo.maxSize" class="pagination-md"
						boundary-links="true" items-per-page="1" rotate="false"
						ng-change="controller.pageChanged();" previous-text="上一页"
						next-text="下一页" first-text="首页" last-text="最后一页"></ul>
					<div class="col-md-1"
						style="top: 27px; left: 98%; width: 117px; position: absolute;">
						跳转
						<div class="col-md-1"
							style="left: 29%; float: left; top: 21px; position: absolute;">
							<input ng-model="controller.queryCondition.forwordPage"
								ng-keyup="enterEvent($event)" type="text" class="form-control"
								style="height: 33px; width: 50px; top: -28px; position: absolute;">
						</div>
						<div style="position: absolute; top: 0px; left: 94%;">页</div>
					</div>
				</div>
			</div>

		</div>
	</div>
</div>